$OpenBSD: patch-pcapu_c,v 1.3 2013/06/19 03:43:46 lteo Exp $
--- pcapu.c.orig	Wed Dec 12 13:31:10 2001
+++ pcapu.c	Sun Mar 31 14:58:54 2013
@@ -19,9 +19,6 @@
 #include <string.h>
 #include <err.h>
 #include <pcap.h>
-#ifdef BSD
-#include <pcap-int.h>
-#endif
 #include <event.h>
 
 #include "pcapu.h"
@@ -78,7 +75,7 @@ pcap_cb(int fd, short event, void *arg)
 
 	if ((pkt = (u_char *) pcap_next(pd, &pkthdr)) == NULL) {
 		if (filemode) {
-			fprintf(stderr, __FUNCTION__": ! add\n");
+			fprintf(stderr, "%s: ! add\n", __FUNCTION__);
 			return;
 		}
 
@@ -89,7 +86,7 @@ pcap_cb(int fd, short event, void *arg)
 	voip_sniff((u_char *)pd, &pkthdr, pkt);
 
  out:
-	timeout_add(&pcapev, &tv);
+	evtimer_add(&pcapev, &tv);
 }
 
 pcap_t *
@@ -133,15 +130,15 @@ pcap_init(char *intf, char *file, char *filter, int sn
 		return (NULL);
 	}
 #ifdef BSD
-	if (file == NULL && bpf_immediate(pd->fd, 1) < 0) {
+	if (file == NULL && bpf_immediate(pcap_fileno(pd), 1) < 0) {
 		perror("ioctl");
 		return (NULL);
 	}
 #endif
 
-	timeout_set(&pcapev, pcap_cb, pd);
+	evtimer_set(&pcapev, pcap_cb, pd);
 	timerclear(&tv);
-	timeout_add(&pcapev, &tv);
+	evtimer_add(&pcapev, &tv);
 
 	return (pd);
 }
